package cn.yuanqiao.cqbc.inspectionLog.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import cn.yuanqiao.cqbc.inspectionLog.mapper.LogDetailsMapper;
import cn.yuanqiao.cqbc.inspectionLog.domain.LogDetails;
import cn.yuanqiao.cqbc.inspectionLog.service.ILogDetailsService;

/**
 * 日志详情Service业务层处理
 * 
 * @author xy
 * @date 2024-06-20
 */
@Service
public class LogDetailsServiceImpl implements ILogDetailsService 
{
    @Autowired
    private LogDetailsMapper logDetailsMapper;

    /**
     * 查询日志详情
     * 
     * @param id 日志详情主键
     * @return 日志详情
     */
    @Override
    public LogDetails selectLogDetailsById(Long id)
    {
        return logDetailsMapper.selectLogDetailsById(id);
    }

    /**
     * 查询日志详情列表
     * 
     * @param logDetails 日志详情
     * @return 日志详情
     */
    @Override
    public List<LogDetails> selectLogDetailsList(LogDetails logDetails)
    {
        return logDetailsMapper.selectLogDetailsList(logDetails);
    }

    /**
     * 新增日志详情
     * 
     * @param logDetails 日志详情
     * @return 结果
     */
    @Override
    public int insertLogDetails(LogDetails logDetails)
    {
        return logDetailsMapper.insertLogDetails(logDetails);
    }

    /**
     * 修改日志详情
     * 
     * @param logDetails 日志详情
     * @return 结果
     */
    @Override
    public int updateLogDetails(LogDetails logDetails)
    {
        return logDetailsMapper.updateLogDetails(logDetails);
    }

    /**
     * 批量删除日志详情
     * 
     * @param ids 需要删除的日志详情主键
     * @return 结果
     */
    @Override
    public int deleteLogDetailsByIds(Long[] ids)
    {
        return logDetailsMapper.deleteLogDetailsByIds(ids,new LogDetails().getTableName());
    }

    /**
     * 删除日志详情信息
     * 
     * @param id 日志详情主键
     * @return 结果
     */
    @Override
    public int deleteLogDetailsById(Long id)
    {
        return logDetailsMapper.deleteLogDetailsById(id);
    }
}
